<%-- 
    Document   : list
    Created on : Nov 6, 2011, 12:22:17 AM
    Author     : xjuraj
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="f" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%@ taglib prefix="s" uri="http://stripes.sourceforge.net/stripes.tld" %>
<s:layout-render name="/WEB-INF/pages/layout.jsp">
    <s:useActionBean beanclass="sk.lieskove.jianghongtiao.paris.webclient.web.ListActionBean" var="list"/>
    <s:layout-component name="head">

    </s:layout-component>
    <s:layout-component name="title">
        <f:message key="page.list.title"/>
    </s:layout-component>
    <s:layout-component name="afterTitle">
        <s:link beanclass="sk.lieskove.jianghongtiao.paris.webclient.web.ListActionBean" 
                event="all">
            <f:message key="page.list.all"></f:message>
        </s:link>
        <br>
        <s:link beanclass="sk.lieskove.jianghongtiao.paris.webclient.web.ListActionBean" 
                event="notProcessed">
            <f:message key="page.list.notProcessed"></f:message>
        </s:link>
    </s:layout-component>
    <s:layout-component name="content">

        <table>
            <thead>
                <tr>
                    <td><f:message key="page.list.table.csId"/></td>
                    <td><f:message key="page.list.table.query"/></td>
                    <td><f:message key="page.list.table.excludeReason"/></td>
                    <td><f:message key="page.list.table.documentType"/></td>
                    <td><f:message key="page.list.table.langCode"/></td>
                    <td><f:message key="page.list.table.mimeType"/></td>
                    <td><f:message key="page.list.table.fileSize"/></td>
                    <td><f:message key="page.list.table.proxy"/></td>
                    <td><f:message key="page.list.table.url"/></td>
                </tr>
            </thead>
            <tbody>
                <c:forEach items="${list.classificationItems}" var="item">
                    <tr>
                        <td>
                            <c:if test="${not empty item.csId}">
                                <s:link beanclass="sk.lieskove.jianghongtiao.paris.webclient.web.ClassificationActionBean" 
                                    event="item" >
                                    <s:param name="csId" value="${item.csId}"/>
                                ${item.csId}
                                </s:link>
                            </c:if>
                            
                        </td>
                        <td>${item.searchQuery}</td>
                        <td>${item.excludeReason}</td>
                        <td>${item.documentType}</td>
                        <td>${item.languageName}</td>
                        <td>${item.mimeType}</td>
                        <td>${item.fileSize}</td>
                        <td>${item.proxyString}</td>
                        <td>${item.trimUrl}</td>
                    </tr>
                </c:forEach>
            </tbody>
        </table>
    </s:layout-component>
    <s:layout-component name="sidebar">

    </s:layout-component>
</s:layout-render>